import Vue from 'vue'
import Vuex from 'vuex'

Vue.use(Vuex)

export default new Vuex.Store({
	state: {
		joblogInput: {
			jobGroup:"0",
			jobId:"0",
		},
		glueJobId:"0"
	},
	actions:{
		changeJOBID(ctx,ob){			
			ctx.commit('changeJOBID',ob)
		},
		changeGlueJobId(ctx,id){			
			ctx.commit('changeGlueJobId',id)
		}
	},
	mutations:{
		changeJOBID(state,ob){
			state.joblogInput.jobId=ob.jobId
			state.joblogInput.jobGroup=ob.jobGroup
			// console.log(ob.jobId)
		},
		changeGlueJobId(state,id){
			state.glueJobId=id
			console.log(state.glueJobId)
		}
	}

	
})